import Request from '../utils/request.js'
let request = new Request().http
// 添加购物车
export const addcarts = function(data) {
	return request({
		url: "api/carts",
		method: "POST",
		data
	})
}
export const getcarts = function(data) {
	return request({
		url: "api/carts",
		data
	})
}
export const putcarts = function(cart) {
	return request({
		url: "api/carts/" + cart,
		method:"put",
	})
}
export const deletecarts = function(cart) {
	return request({
		url: "api/carts/" + cart,
		method:"delete",
	})
}
export const patchcarts = function(data) {
	return request({
		url: "api/carts/checked"
		method:"patch",
		data
	})
}